﻿<html>
<title>CSDN积分查询--清洁工2010版</title>
<head>
	<hta:application icon="http://www.csdn.net/images/favicon.ico" />
	<style>
		#text_username{width:10%;}
		#text_password{width:10%;}
		#table_content{width:100%;height:100%;}
		#textarea_body,#textarea_log{width:100%; height:90%;}
	</style>
	<script type="text/javascript" src="csdnapi.js"></script>
</head>
<body>
<table id="table_content">
	<tr style="height:10%">
		<td>
			用户名：<input type="text" id="text_username" value="***换成自己的用户名***"/>
			密码：<input type="password" id="text_password" value="***换成自己的密码***"/>
			目标：<input type="text" id="text_destuser" value="xiaoheiwu"/>
			<input type="button" value="开始查询" id="button_start" />
	</tr>
	<tr style="height:90%">
		<td>
			日志：<textarea id="textarea_log"></textarea>
		</td>
	</tr>
</table>
<script type="text/javascript">
$("button_start").onclick = function() {
	var result = CSDN.getUserProfile({
		username: $("text_username").value,
		password: $("text_password").value,
		destuser: $("text_destuser").value
	});
	if (result.errId)
		$("textarea_log").value += result.errInfo + "\r\n";
	else $("textarea_log").value += format(
		"-------\r\n" + 
		"用户名：${username}\r\n" +
		"昵　称：${nickName}\r\n" +
		"专家分：${techExpertPoint}\r\n" +
		"水　分：${nonTechExpertPoint}\r\n" +
		"可用分：${point}\r\n", result);
};
</script>
</body>
</html>
